<template>
<div>

  <p>用户名：<input type="text" v-model="form.username"></p>
  <p>密码：<input type="text" v-model="form.password"></p>
  <p>手机号：<input type="text" v-model="form.mobile"></p>
  <p>验证码：<input type="text" v-model="form.yzm"></p>
  <button @click="hqyzm">获取验证码</button>
  <p><button @click="addlo">添加</button></p>

</div>
</template>

<script>
export default {
  name: "a_1",
  data(){
    return{
      form:{}
    }
  },
  methods:{
    hqyzm(){
      this.axios.get('user/Deng/?mobile='+this.form.mobile)
      .then(res=>{
        console.log(res.data)
      })
    },
    addlo(){
      this.axios.post('user/Deng/',this.form)
      .then(res=>{
        console.log(res.data)
      })
    }
  },
  mounted() {
  }
}
</script>

<style scoped>

</style>
